#include "widget.h"
#include "ui_widget.h"

Widget::Widget(QWidget *parent)
    : QWidget(parent)
    , ui(new Ui::Widget)
{
    ui->setupUi(this);
    srand(time(0));
}

Widget::~Widget()
{
    delete ui;
}

//void Widget::on_pushButton_yesyesyes_clicked()
//{
//    ui->label->setText("我胡云凯爱说实话, 池岸洋是傻逼");
//}

void Widget::on_pushButton_say_good_pressed()
{
    ui->label->setText("我张展华也爱说实话, 池岸洋不是傻逼");

    //
    int width = this->geometry().width();
    int height = this->geometry().height();

    int x = rand() % width;
    int y = rand() % height;

    ui->pushButton_say_good->move(x, y);
}
